<%@ page language="java" import="java.util.*,com.google.gson.*" pageEncoding="utf-8"%>
<!-- 店铺首页 -->
<!DOCTYPE html>
<html class="ui-viewport-640" lang="zh-CN" >
<head>
    <meta name="keywords" content="Bidcms,微信商城,粉丝营销,微信商城运营" />
    <meta name="description" content="Bidcms是帮助商家在微信上搭建微信商城的平台，提供店铺、商品、订单、物流、消息和客户的管理模块，同时还提供丰富的营销应用和活动插件。" />
    <meta name="HandheldFriendly" content="True">
    <meta name="MobileOptimized" content="320">
    <meta name="format-detection" content="telephone=no">
    <meta http-equiv="cleartype" content="on">
    <!-- dns prefetch -->
    <link rel="icon" href="${webRoot}/static/v2/image/favicon.ico" />
    <title>${pagetitle}</title>
    <!-- _global -->
    <script>
	var _global =${base};
	_global.url=${url};
	_global.mp_data=${mp_data};
	_global.query_path="/show/homepage";
	_global.module="show";
	_global.controller="show_controller";
	_global.action="homepage_action";
</script>

    <!-- meta viewport -->
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
    
    <!-- CSS -->
    <link rel="stylesheet" href="${webRoot}/static/v2/build_css/stylesheets/wap/base.css" >    
	<link rel="stylesheet" href="${webRoot}/static/v2/build_css/stylesheets/wap/projects/showcase.css" >    
	
	</head>

<body>
        <!-- container -->
    <div class="container">       
<div class="content js-mini-height">
		
			<div class="content-body">
			<div class="ui-loading" id="js-loading">
				<div class="loading-animate"></div>
			</div>
			
			<%
				JsonArray dataJson = (JsonArray)request.getAttribute("dataJson");
				JsonObject jsonData1 = (JsonObject)dataJson.get(0);
				JsonObject jsonData2 = (JsonObject)dataJson.get(1);
			 %>
			<% if(jsonData2.get("first_page_wipe_image_url")!=null){%>
			<div class="ui-mask" id="js-mask" data-url="<% out.write(jsonData2.get("first_page_wipe_image_url").getAsString());%>" data-bg="<% out.write(jsonData2.get("first_page_image_url").getAsString());%>"></div>
			<% }%>
			<div class="tpl-scroll js-tpl-scroll-container">
				<div class="swiper-container js-tpl-scroll" data-loop="<% if(jsonData2.get("loop").getAsInt()>0){%>true<% }%>">
					<div class="swiper-wrapper">
						<div class="swiper-slide" data-hash="slide_first">
							<i id="wxcover" data-wxcover="<% out.write(jsonData2.get("first_page_image_url").getAsString());%>" style="background-image:url(<% out.write(jsonData2.get("first_page_image_url").getAsString());%>);"></i>
							<div class="ui-up-arrow js-up-arrow">
								<img src="${webRoot}/static/v2/image/scroll/gesture_mini.png" alt="滑动提示" width="230" height="280">
							</div>
						</div>
						<% 
							JsonArray sub_entry = (JsonArray)jsonData2.get("sub_entry");
						for(int i = 0;i<sub_entry.size();i++){%>
						<div class="swiper-slide" data-hash="slide_<% out.write(i+2);%>">
								<i style="background-image:url('<% out.write(jsonData2.get("image_url").getAsString());%>');"></i>
						</div>
						<% }%>
						<div class="swiper-slide" data-hash="slide_last">
							<i class="js-lazy-scroll" data-src="<% out.write(jsonData2.get("last_page_image_url").getAsString());%>"></i>
						</div>
					</div>
				</div>
				<% if(jsonData2.get("music_icon").getAsInt()>0 &&jsonData2.get("music_url")!=null){%>
				<div class="ui-right-btns js-beta-coffee js-audio" data-src="<% out.write(jsonData2.get("music_url").getAsString());%>">
					<i class="ui-music-btn js-music-btn"></i>
				</div>
				<% }%>
				<div class="ui-left-btns">
				<a href="index?con=show"><i class="ui-homepage-btn"></i></a>
				</div>
			</div>
			</div>
			<jsp:include  page="../../global_sidebar.jsp"/>
			</div>
			
</div>

<!-- JS -->
<script src="${webRoot}/static/v2/vendor/jquery-2.0.3.min.js" ></script>
<script src="${webRoot}/static/v2/build/wap/base.js" ></script>
<script src="${webRoot}/static/v2/build/wap/swiper/main.js" ></script>                
<script src="${webRoot}/static/v2/build/wap/showcase/base.js" ></script>
<script src="${webRoot}/static/v2/build/wap/showcase/modules/scroll.js" ></script>
<div id="right-icon" class="icon-hide  no-border hide" data-count = "1">
<div class="right-icon-container clearfix" style="width: 50px">

<a id="global-cart" href="http://wap.koudaitong.com/v2/trade/cart?kdt_id=355963" class="no-text" style="background-image: url(http://static.koudaitong.com/v2/image/setting/shopping-cart/2x/s0.png);background-size: 50px 50px;background-position: center;">
<p class="right-icon-img"></p>
<p class="right-icon-txt">购物车</p>
</a>
</div>
</div>



<script src="${webRoot}/static/v2/build/wap/showcase/global_icon.js" ></script>

</body>
</html>